<?php


namespace Ionafan2\GetonlyimgBundle\DataFixtures\ORM;

//use Doctrine\Common\DataFixtures\AbstractFixture;
//use Doctrine\Common\DataFixtures\OrderedFixtureInterface;
use Doctrine\Common\Persistence\ObjectManager;
use Ionafan2\GetonlyimgBundle\Entity\Url;

/**
 * Projects fixtures
 *
 * @author Stepan Tanasiychuk <ceo@stfalcon.com>
 */
class LoadUrlData //extends AbstractFixture implements OrderedFixtureInterface
{
    /**
     * Create and load categories fixtures to database
     *
     * @param \Doctrine\Common\Persistence\ObjectManager $manager Entity manager object
     *
     * @return void
     */
    public function load(ObjectManager $manager)
    {
        $url = new Url();

        $manager->persist($url);
        $manager->flush();

        $this->addReference('url', $url);
    }

    /**
     * Get order number
     *
     * @return integer
     */
    public function getOrder()
    {
        return 1; // the order in which fixtures will be loaded
    }

}
